package com.qunar.qcf.filter.executor;

import com.qunar.qcf.core.session.IoEvent;

/**
 * Estimates the amount of memory that the specified {@link IoEvent} occupies
 * in the current JVM.
 * 
 */
public interface IoEventSizeEstimator {
    /**
     * Estimate the IoEvent size in numberof bytes
     * @param event The event we want to estimate the size of
     * @return The estimated size of this event
     */
    int estimateSize(IoEvent event);
}
